package java2022_07_11;

import java.io.File;
import java.io.IOException;

public class FileDemo3 {
    public static void main(String[] args) throws IOException, InterruptedException {
        File file = new File("helloWorld.txt");
        file.createNewFile();
        Thread.sleep(5000);
        System.out.println(file.delete());
    }
}
